clipboard-win
This crate provide simple means to operate with Windows clipboard.
Note keeping Clipboard around:
In Windows Clipboard opens globally and only one application can set data onto format at the time.
Therefore as soon as operations are finished, user is advised to close Clipboard.
Clipboard
All read and write access to Windows clipboard requires user to open it.
Usage
Manually lock clipboard
use ;
const SAMPLE: &str = "MY loli sample ^^";
let _clip = new_attempts.expect;
Unicode.write_clipboard.expect;
let mut output = String new;
assert_eq!;
assert_eq!;
//Efficiently re-use buffer ;)
output.clear;
assert_eq!;
assert_eq!;
//Or take the same string twice?
assert_eq!;
assert_eq!;
Simplified API
use ;
let text = "my sample ><";
set_clipboard.expect;
//Type is necessary as string can be stored in various storages
let result: String = get_clipboard.expect;
assert_eq!